#ifndef __PRM_2D__H__
#define __PRM_2D__H__

#include "Graph.h"
#include "Kd_tree.h"
#include "basic_typedef.h"

class CollisionDetector2D;
class Sampler2D;

class Prm2D {
  public:
    Prm2D(const CollisionDetector2D& col, const Sampler2D& sampler);

    void generateRoadmap(Point_2 start, Point_2 target,
                          int numberVertices, int kNearest);

    const Graph<Point_2>& getGraph() const;

  private:
    const CollisionDetector2D* m_collisionDetector;
    const Sampler2D* m_sampler;

    Graph<Point_2> m_graph;
    Kd_tree_2<Kernel> m_kdTree;
};

#endif  // __PRM_2D__H__
